<?php
include_once("TestDetail.php");

class Test
{
	public $Id;
	public $CreatedBy;
	public $CreationOn;
	public $Name;
	public $Description;
	public $Details;
	
	function __construct()
	{
		$this->Details = array();
	}
	
	public function GetTotalMarks()
	{
		$marks = 0;
		for($i = 0; $i < count($this->Details); $i++)
		{
			$marks = $marks + $this->Details[$i]->Marks;
		}
		return $marks;
	}
}

?>